package com.example.accessingdatajpa.service;

import com.example.accessingdatajpa.pojo.FirstPagePicture;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import javax.transaction.Transactional;
import java.io.IOException;

public interface IFirstPagePicService {
    //insert a picture of fruit
    @Transactional
    void insertFirstPagePic(FirstPagePicture firstPagePicture, MultipartFile file) throws IOException;


    //find the fruit's picture by id
    @Transactional
    void queryFirstPagePicById(Long id, HttpServletResponse response) throws IOException;

    //update the fruit's picture by id
    @Transactional
    void updateFirstPagePicById(Long id, MultipartFile file) throws IOException;
}
